<template>
	<view>
		<view class="content">
			<swiper class="swiper" :indicator-dots="true" :autoplay="true" :interval="3000" :duration="500" :circular="true" 
			indicator-color="rgba(255, 255, 255, 0.35)" indicator-active-color="#ffffff">
				<swiper-item v-for="(item, index) in dataObject.lists" :key="index" @click="clickToItem(item)">
					<image class="banner" :src="item.thumbnail||item.cover" mode=""></image>
				</swiper-item>
			</swiper>
		</view>
		
	</view>
</template>

<script>
	export default {
		data() {
			return{
				
			}
		},
		props:{
			dataObject: {
				type: Object,
				default: function(){
					return []
				}
			},
		},
		methods: {
			clickToItem(res){
				// console.log(res)
			    // res.jump_type
			}
		}
	}
</script>

<style lang="scss">
	.content{
		display: flex;
		height: 280rpx;
		justify-content: center; //水平居中
		align-items: center; //垂直居中
		overflow: hidden;//内容超出隐藏
		padding: 0px 15px;
		margin-bottom: 18px;
				
		.swiper{
			width: 100%;
			height: 280rpx;
			.banner{
				width: 100%;
				height: 280rpx;
				border-radius: 10px;
				// background-color: orange;
			}
		}
	}
</style>